<template>
  <a-modal @cancel="close" title="操作记录" width="75vw" :visible="visible" unmount-on-close>
    <div class="insure-edit-content">
      <OperateLog type="38" :list="list" />
    </div>
    <template #footer>
      <a-button @click="close">关闭</a-button>
    </template>
  </a-modal>
</template>

<script setup name="OperateLogModal">
  import { ref } from 'vue'

  const visible = ref(false)
  const list = [
    {
      title: '操作时间',
      dataIndex: 'operateTime',
      width: 180,
    },
    { title: '操作页面', dataIndex: 'businessStatusName', width: 180 },
    { title: '操作人', dataIndex: 'userName', width: 180 },
    { title: '描述', slotName: 'log' },
  ]
  // 修改
  const open = () => {
    visible.value = true
  }
  // 关闭
  const close = () => {
    visible.value = false
  }

  defineExpose({
    open,
  })
</script>
<style lang="less" scoped>
  .insure-edit-content {
    overflow-x: hidden;
    max-height: 80vh;
  }
</style>
